package xin.nick.cloud.user.client;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * @author Nick
 * @date 2021/8/1
 * @description
 */
@FeignClient(name="my-service-code")
public interface ServiceCodeClient {

    /**
     * 验证
     * @param email
     * @param code
     * @return
     */
    @RequestMapping(value = "/code/validate/{email}/{code}", method = RequestMethod.GET)
    int validate(@PathVariable("email") String email,
                        @PathVariable("code") String code);

}
